fix pneu and fadec bug, also add DES nasal and xml
This commit is contained in:
parent
1e87bb95d1
commit
649c61b2f0
6 changed files with 89 additions and 6 deletions
|
@ -202,6 +202,28 @@
|
||||||
</condition>
|
</condition>
|
||||||
</model>
|
</model>
|
||||||
|
|
||||||
|
<model>
|
||||||
|
<name>DES</name>
|
||||||
|
<path>PERF/DES/DES.xml</path>
|
||||||
|
<offsets>
|
||||||
|
<heading-deg>180</heading-deg>
|
||||||
|
<roll-deg>180</roll-deg>
|
||||||
|
<pitch-deg>90</pitch-deg>
|
||||||
|
</offsets>
|
||||||
|
<condition>
|
||||||
|
<and>
|
||||||
|
<greater-than-equals>
|
||||||
|
<property>/systems/electrical/bus/ac1</property>
|
||||||
|
<value>110</value>
|
||||||
|
</greater-than-equals>
|
||||||
|
<equals>
|
||||||
|
<property>/MCDU[0]/page</property>
|
||||||
|
<value>DES</value>
|
||||||
|
</equals>
|
||||||
|
</and>
|
||||||
|
</condition>
|
||||||
|
</model>
|
||||||
|
|
||||||
<model>
|
<model>
|
||||||
<name>DATA2</name>
|
<name>DATA2</name>
|
||||||
<path>DATA2/DATA2.xml</path>
|
<path>DATA2/DATA2.xml</path>
|
||||||
|
|
|
@ -202,6 +202,28 @@
|
||||||
</condition>
|
</condition>
|
||||||
</model>
|
</model>
|
||||||
|
|
||||||
|
<model>
|
||||||
|
<name>DES</name>
|
||||||
|
<path>PERF/DES/DES.xml</path>
|
||||||
|
<offsets>
|
||||||
|
<heading-deg>180</heading-deg>
|
||||||
|
<roll-deg>180</roll-deg>
|
||||||
|
<pitch-deg>90</pitch-deg>
|
||||||
|
</offsets>
|
||||||
|
<condition>
|
||||||
|
<and>
|
||||||
|
<greater-than-equals>
|
||||||
|
<property>/systems/electrical/bus/ac2</property>
|
||||||
|
<value>110</value>
|
||||||
|
</greater-than-equals>
|
||||||
|
<equals>
|
||||||
|
<property>/MCDU[1]/page</property>
|
||||||
|
<value>DES</value>
|
||||||
|
</equals>
|
||||||
|
</and>
|
||||||
|
</condition>
|
||||||
|
</model>
|
||||||
|
|
||||||
<model>
|
<model>
|
||||||
<name>DATA2</name>
|
<name>DATA2</name>
|
||||||
<path>DATA2/DATA2.xml</path>
|
<path>DATA2/DATA2.xml</path>
|
||||||
|
|
|
@ -69,6 +69,10 @@ var lskbutton = func(btn) {
|
||||||
radnavInput("L2");
|
radnavInput("L2");
|
||||||
} else if (getprop("/MCDU[0]/page") == "CLB") {
|
} else if (getprop("/MCDU[0]/page") == "CLB") {
|
||||||
initInputA("L5"); # Does the same thing as on the INIT page
|
initInputA("L5"); # Does the same thing as on the INIT page
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "CRZ") {
|
||||||
|
initInputA("L5");
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "DES") {
|
||||||
|
initInputA("L5");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[0]/scratchpad-msg", "1");
|
setprop("/MCDU[0]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -102,6 +106,10 @@ var lskbutton = func(btn) {
|
||||||
perfTOInput("L5");
|
perfTOInput("L5");
|
||||||
} else if (getprop("/MCDU[0]/page") == "CLB") {
|
} else if (getprop("/MCDU[0]/page") == "CLB") {
|
||||||
perfCLBInput("L5");
|
perfCLBInput("L5");
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "CRZ") {
|
||||||
|
perfCRZInput("L5");
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "DES") {
|
||||||
|
perfDESInput("L5");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[0]/scratchpad-msg", "1");
|
setprop("/MCDU[0]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -113,6 +121,8 @@ var lskbutton = func(btn) {
|
||||||
perfCLBInput("L6");
|
perfCLBInput("L6");
|
||||||
} else if (getprop("/MCDU[0]/page") == "CRZ") {
|
} else if (getprop("/MCDU[0]/page") == "CRZ") {
|
||||||
perfCRZInput("L6");
|
perfCRZInput("L6");
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "DES") {
|
||||||
|
perfDESInput("L6");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[0]/scratchpad-msg", "1");
|
setprop("/MCDU[0]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -173,6 +183,8 @@ var rskbutton = func(btn) {
|
||||||
perfTOInput("R6");
|
perfTOInput("R6");
|
||||||
} else if (getprop("/MCDU[0]/page") == "CLB") {
|
} else if (getprop("/MCDU[0]/page") == "CLB") {
|
||||||
perfCLBInput("R6");
|
perfCLBInput("R6");
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "CRZ") {
|
||||||
|
perfCRZInput("R6");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[0]/scratchpad-msg", "1");
|
setprop("/MCDU[0]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[0]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -688,9 +700,15 @@ var perfCRZInput = func(key) {
|
||||||
if (key == "L6") {
|
if (key == "L6") {
|
||||||
setprop("/MCDU[0]/page", "CLB");
|
setprop("/MCDU[0]/page", "CLB");
|
||||||
}
|
}
|
||||||
# if (key == "R6") {
|
if (key == "R6") {
|
||||||
# setprop("/MCDU[0]/page", "DES");
|
setprop("/MCDU[0]/page", "DES");
|
||||||
# }
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
var perfDESInput = func(key) {
|
||||||
|
if (key == "L6") {
|
||||||
|
setprop("/MCDU[0]/page", "CRZ");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var arrowbutton = func(btn) {
|
var arrowbutton = func(btn) {
|
||||||
|
|
|
@ -69,6 +69,10 @@ var lskbutton = func(btn) {
|
||||||
radnavInput("L2");
|
radnavInput("L2");
|
||||||
} else if (getprop("/MCDU[1]/page") == "CLB") {
|
} else if (getprop("/MCDU[1]/page") == "CLB") {
|
||||||
initInputA("L5"); # Does the same thing as on the INIT page
|
initInputA("L5"); # Does the same thing as on the INIT page
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "CRZ") {
|
||||||
|
initInputA("L5");
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "DES") {
|
||||||
|
initInputA("L5");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[1]/scratchpad-msg", "1");
|
setprop("/MCDU[1]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -102,6 +106,10 @@ var lskbutton = func(btn) {
|
||||||
perfTOInput("L5");
|
perfTOInput("L5");
|
||||||
} else if (getprop("/MCDU[1]/page") == "CLB") {
|
} else if (getprop("/MCDU[1]/page") == "CLB") {
|
||||||
perfCLBInput("L5");
|
perfCLBInput("L5");
|
||||||
|
} else if (getprop("/MCDU[1]/page") == "CRZ") {
|
||||||
|
perfCRZInput("L5");
|
||||||
|
} else if (getprop("/MCDU[1]/page") == "DES") {
|
||||||
|
perfDESInput("L5");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[1]/scratchpad-msg", "1");
|
setprop("/MCDU[1]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -113,6 +121,8 @@ var lskbutton = func(btn) {
|
||||||
perfCLBInput("L6");
|
perfCLBInput("L6");
|
||||||
} else if (getprop("/MCDU[1]/page") == "CRZ") {
|
} else if (getprop("/MCDU[1]/page") == "CRZ") {
|
||||||
perfCRZInput("L6");
|
perfCRZInput("L6");
|
||||||
|
} else if (getprop("/MCDU[0]/page") == "DES") {
|
||||||
|
perfDESInput("L6");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[1]/scratchpad-msg", "1");
|
setprop("/MCDU[1]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -173,6 +183,8 @@ var rskbutton = func(btn) {
|
||||||
perfTOInput("R6");
|
perfTOInput("R6");
|
||||||
} else if (getprop("/MCDU[1]/page") == "CLB") {
|
} else if (getprop("/MCDU[1]/page") == "CLB") {
|
||||||
perfCLBInput("R6");
|
perfCLBInput("R6");
|
||||||
|
} else if (getprop("/MCDU[1]/page") == "CRZ") {
|
||||||
|
perfCRZInput("R6");
|
||||||
} else {
|
} else {
|
||||||
setprop("/MCDU[1]/scratchpad-msg", "1");
|
setprop("/MCDU[1]/scratchpad-msg", "1");
|
||||||
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
setprop("/MCDU[1]/scratchpad", "NOT ALLOWED");
|
||||||
|
@ -688,9 +700,15 @@ var perfCRZInput = func(key) {
|
||||||
if (key == "L6") {
|
if (key == "L6") {
|
||||||
setprop("/MCDU[1]/page", "CLB");
|
setprop("/MCDU[1]/page", "CLB");
|
||||||
}
|
}
|
||||||
# if (key == "R6") {
|
if (key == "R6") {
|
||||||
# setprop("/MCDU[1]/page", "DES");
|
setprop("/MCDU[1]/page", "DES");
|
||||||
# }
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
var perfDESInput = func(key) {
|
||||||
|
if (key == "L6") {
|
||||||
|
setprop("/MCDU[1]/page", "CRZ");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var arrowbutton = func(btn) {
|
var arrowbutton = func(btn) {
|
||||||
|
|
|
@ -23,6 +23,7 @@ setlistener("/sim/signals/fdm-initialized", func {
|
||||||
setprop("/systems/thrust/mct-lim", 0.0);
|
setprop("/systems/thrust/mct-lim", 0.0);
|
||||||
setprop("/systems/thrust/clb-lim", 0.0);
|
setprop("/systems/thrust/clb-lim", 0.0);
|
||||||
setprop("/systems/thrust/lim-flex", 0);
|
setprop("/systems/thrust/lim-flex", 0);
|
||||||
|
setprop("/engines/flex-derate", 0);
|
||||||
thrustt.start();
|
thrustt.start();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -51,6 +51,8 @@ var pneu_init = func {
|
||||||
setprop("/systems/ventilation/avionics/inletvalve", "0");
|
setprop("/systems/ventilation/avionics/inletvalve", "0");
|
||||||
setprop("/systems/ventilation/lavatory/extractfan", 0);
|
setprop("/systems/ventilation/lavatory/extractfan", 0);
|
||||||
setprop("/systems/ventilation/lavatory/extractvalve", "0");
|
setprop("/systems/ventilation/lavatory/extractvalve", "0");
|
||||||
|
setprop("/systems/pressurization/ambientpsi", "0");
|
||||||
|
setprop("/systems/pressurization/cabinpsi", "0");
|
||||||
pneu_timer.start();
|
pneu_timer.start();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Reference in a new issue