Merge branch 'master' of github.com:it0uchpods/A320Family
This commit is contained in:
commit
0eb4958798
4 changed files with 182 additions and 5 deletions
|
@ -3199,6 +3199,113 @@
|
||||||
</animation>
|
</animation>
|
||||||
|
|
||||||
<!-- Cabin Pressurization -->
|
<!-- Cabin Pressurization -->
|
||||||
|
<animation>
|
||||||
|
<type>pick</type>
|
||||||
|
<object-name>ManVSCTLSwitch</object-name>
|
||||||
|
<action>
|
||||||
|
<button>0</button>
|
||||||
|
<repeatable>true</repeatable>
|
||||||
|
<binding>
|
||||||
|
<command>nasal</command>
|
||||||
|
<script>libraries.increaseManVS();</script>
|
||||||
|
</binding>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>1</value>
|
||||||
|
</binding>
|
||||||
|
<mod-up>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>0</value>
|
||||||
|
</binding>
|
||||||
|
</mod-up>
|
||||||
|
</action>
|
||||||
|
<action>
|
||||||
|
<button>1</button>
|
||||||
|
<repeatable>true</repeatable>
|
||||||
|
<binding>
|
||||||
|
<command>nasal</command>
|
||||||
|
<script>libraries.decreaseManVS();</script>
|
||||||
|
</binding>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>-1</value>
|
||||||
|
</binding>
|
||||||
|
<mod-up>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>0</value>
|
||||||
|
</binding>
|
||||||
|
</mod-up>
|
||||||
|
</action>
|
||||||
|
<action>
|
||||||
|
<button>3</button>
|
||||||
|
<repeatable>true</repeatable>
|
||||||
|
<binding>
|
||||||
|
<command>nasal</command>
|
||||||
|
<script>libraries.increaseManVS();</script>
|
||||||
|
</binding>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>1</value>
|
||||||
|
</binding>
|
||||||
|
<mod-up>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>0</value>
|
||||||
|
</binding>
|
||||||
|
</mod-up>
|
||||||
|
</action>
|
||||||
|
<action>
|
||||||
|
<button>4</button>
|
||||||
|
<repeatable>true</repeatable>
|
||||||
|
<binding>
|
||||||
|
<command>nasal</command>
|
||||||
|
<script>libraries.decreaseManVS();</script>
|
||||||
|
</binding>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>-1</value>
|
||||||
|
</binding>
|
||||||
|
<mod-up>
|
||||||
|
<binding>
|
||||||
|
<command>property-assign</command>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<value>0</value>
|
||||||
|
</binding>
|
||||||
|
</mod-up>
|
||||||
|
</action>
|
||||||
|
</animation>
|
||||||
|
|
||||||
|
<animation>
|
||||||
|
<name>Man VS rotate</name>
|
||||||
|
<type>rotate</type>
|
||||||
|
<object-name>ManVSCTLSwitch</object-name>
|
||||||
|
<property>/systems/pressurization/outflowpos-man-sw</property>
|
||||||
|
<interpolation>
|
||||||
|
<entry><ind>-1</ind><dep>-35</dep></entry>
|
||||||
|
<entry><ind>0</ind><dep>0</dep></entry>
|
||||||
|
<entry><ind>1</ind><dep>35</dep></entry>
|
||||||
|
</interpolation>
|
||||||
|
<axis>
|
||||||
|
<x>0</x>
|
||||||
|
<y>1</y>
|
||||||
|
<z>0</z>
|
||||||
|
</axis>
|
||||||
|
<center>
|
||||||
|
<x-m>-0.0128</x-m>
|
||||||
|
<y-m> 0.0433</y-m>
|
||||||
|
<z-m>-0.2186</z-m>
|
||||||
|
</center>
|
||||||
|
</animation>
|
||||||
|
|
||||||
<animation>
|
<animation>
|
||||||
<type>pick</type>
|
<type>pick</type>
|
||||||
<object-name>CabinPressModeBtn</object-name>
|
<object-name>CabinPressModeBtn</object-name>
|
||||||
|
@ -3267,6 +3374,7 @@
|
||||||
<animation>
|
<animation>
|
||||||
<type>pick</type>
|
<type>pick</type>
|
||||||
<object-name>DitchBtn1</object-name>
|
<object-name>DitchBtn1</object-name>
|
||||||
|
<object-name>DitchBtn2</object-name>
|
||||||
<object-name>DitchBtn2O</object-name>
|
<object-name>DitchBtn2O</object-name>
|
||||||
<action>
|
<action>
|
||||||
<button>0</button>
|
<button>0</button>
|
||||||
|
@ -4140,6 +4248,7 @@
|
||||||
</binding>
|
</binding>
|
||||||
</action>
|
</action>
|
||||||
</animation>
|
</animation>
|
||||||
|
|
||||||
<animation>
|
<animation>
|
||||||
<name>Seatbelt sign rotate</name>
|
<name>Seatbelt sign rotate</name>
|
||||||
<type>rotate</type>
|
<type>rotate</type>
|
||||||
|
|
|
@ -398,3 +398,19 @@ var toggleSTD = func {
|
||||||
setprop("/modes/altimeter/std", 1);
|
setprop("/modes/altimeter/std", 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var increaseManVS = func {
|
||||||
|
var manvs = getprop("/systems/pressurization/outflowpos-man");
|
||||||
|
var auto = getprop("/systems/pressurization/auto");
|
||||||
|
if (manvs <= 1 and manvs >= 0 and !auto) {
|
||||||
|
setprop("/systems/pressurization/outflowpos-man", manvs + 0.001);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
var decreaseManVS = func {
|
||||||
|
var manvs = getprop("/systems/pressurization/outflowpos-man");
|
||||||
|
var auto = getprop("/systems/pressurization/auto");
|
||||||
|
if (manvs <= 1 and manvs >= 0 and !auto) {
|
||||||
|
setprop("/systems/pressurization/outflowpos-man", manvs - 0.001);
|
||||||
|
}
|
||||||
|
}
|
|
@ -16,7 +16,6 @@ var pneu_init = func {
|
||||||
setprop("/controls/pneumatic/switches/ram-air", 0);
|
setprop("/controls/pneumatic/switches/ram-air", 0);
|
||||||
setprop("/controls/pneumatic/switches/pack-flo", 9); # LO: 7, NORM: 9, HI: 11.
|
setprop("/controls/pneumatic/switches/pack-flo", 9); # LO: 7, NORM: 9, HI: 11.
|
||||||
setprop("/controls/pneumatic/switches/xbleed", 1); # SHUT: 0, AUTO: 1, OPEN: 2. # I will simulate later, once I get the knob animated. -JD
|
setprop("/controls/pneumatic/switches/xbleed", 1); # SHUT: 0, AUTO: 1, OPEN: 2. # I will simulate later, once I get the knob animated. -JD
|
||||||
setprop("/controls/pressurization/auto", 1);
|
|
||||||
setprop("/systems/pneumatic/bleed1", 0);
|
setprop("/systems/pneumatic/bleed1", 0);
|
||||||
setprop("/systems/pneumatic/bleed2", 0);
|
setprop("/systems/pneumatic/bleed2", 0);
|
||||||
setprop("/systems/pneumatic/bleedapu", 0);
|
setprop("/systems/pneumatic/bleedapu", 0);
|
||||||
|
@ -30,6 +29,7 @@ var pneu_init = func {
|
||||||
setprop("/systems/pneumatic/eng1-starter", 0);
|
setprop("/systems/pneumatic/eng1-starter", 0);
|
||||||
setprop("/systems/pneumatic/eng2-starter", 0);
|
setprop("/systems/pneumatic/eng2-starter", 0);
|
||||||
setprop("/FMGC/internal/dep-arpt", "");
|
setprop("/FMGC/internal/dep-arpt", "");
|
||||||
|
var altitude = getprop("/instrumentation/altimeter/indicated-altitude-ft");
|
||||||
setprop("/systems/pressurization/mode", "GN");
|
setprop("/systems/pressurization/mode", "GN");
|
||||||
setprop("/systems/pressurization/vs", "0");
|
setprop("/systems/pressurization/vs", "0");
|
||||||
setprop("/systems/pressurization/targetvs", "0");
|
setprop("/systems/pressurization/targetvs", "0");
|
||||||
|
@ -39,20 +39,23 @@ var pneu_init = func {
|
||||||
setprop("/systems/pressurization/outflowpos", "0");
|
setprop("/systems/pressurization/outflowpos", "0");
|
||||||
setprop("/systems/pressurization/deltap-norm", "0");
|
setprop("/systems/pressurization/deltap-norm", "0");
|
||||||
setprop("/systems/pressurization/outflowpos-norm", "0");
|
setprop("/systems/pressurization/outflowpos-norm", "0");
|
||||||
var altitude = getprop("/instrumentation/altimeter/indicated-altitude-ft");
|
setprop("/systems/pressurization/outflowpos-man", "0.5");
|
||||||
|
setprop("/systems/pressurization/outflowpos-man-sw", "0");
|
||||||
|
setprop("/systems/pressurization/outflowpos-norm-cmd", "0");
|
||||||
setprop("/systems/pressurization/cabinalt", altitude);
|
setprop("/systems/pressurization/cabinalt", altitude);
|
||||||
setprop("/systems/pressurization/targetalt", altitude);
|
setprop("/systems/pressurization/targetalt", altitude);
|
||||||
setprop("/systems/pressurization/diff-to-target", "0");
|
setprop("/systems/pressurization/diff-to-target", "0");
|
||||||
setprop("/systems/pressurization/ditchingpb", 0);
|
setprop("/systems/pressurization/ditchingpb", 0);
|
||||||
setprop("/systems/pressurization/targetvs", "0");
|
setprop("/systems/pressurization/targetvs", "0");
|
||||||
|
setprop("/systems/pressurization/ambientpsi", "0");
|
||||||
|
setprop("/systems/pressurization/cabinpsi", "0");
|
||||||
|
setprop("/systems/pressurization/manvs-cmd", "0");
|
||||||
setprop("/systems/ventilation/cabin/fans", 0); # aircon fans
|
setprop("/systems/ventilation/cabin/fans", 0); # aircon fans
|
||||||
setprop("/systems/ventilation/avionics/fan", 0);
|
setprop("/systems/ventilation/avionics/fan", 0);
|
||||||
setprop("/systems/ventilation/avionics/extractvalve", "0");
|
setprop("/systems/ventilation/avionics/extractvalve", "0");
|
||||||
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");
|
|
||||||
setprop("/controls/deice/eng1-on", 0);
|
setprop("/controls/deice/eng1-on", 0);
|
||||||
setprop("/controls/deice/eng2-on", 0);
|
setprop("/controls/deice/eng2-on", 0);
|
||||||
pneu_timer.start();
|
pneu_timer.start();
|
||||||
|
@ -217,6 +220,7 @@ var master_pneu = func {
|
||||||
var altitude = getprop("/instrumentation/altimeter/indicated-altitude-ft");
|
var altitude = getprop("/instrumentation/altimeter/indicated-altitude-ft");
|
||||||
var airport_arr_elev_ft = getprop("autopilot/route-manager/destination/field-elevation-ft");
|
var airport_arr_elev_ft = getprop("autopilot/route-manager/destination/field-elevation-ft");
|
||||||
var vs = getprop("/systems/pressurization/vs-norm");
|
var vs = getprop("/systems/pressurization/vs-norm");
|
||||||
|
var manvs = getprop("/systems/pressurization/manvs-cmd");
|
||||||
var ditch = getprop("/systems/pressurization/ditchingpb");
|
var ditch = getprop("/systems/pressurization/ditchingpb");
|
||||||
var outflowpos = getprop("/systems/pressurization/outflowpos");
|
var outflowpos = getprop("/systems/pressurization/outflowpos");
|
||||||
var cabinalt = getprop("/systems/pressurization/cabinalt");
|
var cabinalt = getprop("/systems/pressurization/cabinalt");
|
||||||
|
@ -240,8 +244,10 @@ var master_pneu = func {
|
||||||
setprop("/systems/pressurization/vs", targetvs);
|
setprop("/systems/pressurization/vs", targetvs);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cabinalt != targetalt and !wowl and !wowr and !pause) {
|
if (cabinalt != targetalt and !wowl and !wowr and !pause and auto) {
|
||||||
setprop("/systems/pressurization/cabinalt", cabinalt + ((vs / 60) / 10));
|
setprop("/systems/pressurization/cabinalt", cabinalt + ((vs / 60) / 10));
|
||||||
|
} else if (!auto and !pause) {
|
||||||
|
setprop("/systems/pressurization/cabinalt", cabinalt + ((manvs / 60) / 10));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ditch and auto) {
|
if (ditch and auto) {
|
||||||
|
|
|
@ -368,6 +368,32 @@
|
||||||
<max-rate-of-change>1</max-rate-of-change>
|
<max-rate-of-change>1</max-rate-of-change>
|
||||||
</filter>
|
</filter>
|
||||||
|
|
||||||
|
<filter>
|
||||||
|
<name>Outflow logic</name>
|
||||||
|
<type>gain</type>
|
||||||
|
<gain>1</gain>
|
||||||
|
<update-interval-secs type="double">0.1</update-interval-secs>
|
||||||
|
<input>
|
||||||
|
<condition>
|
||||||
|
<equals>
|
||||||
|
<property>/systems/pressurization/auto</property>
|
||||||
|
<value>0</value>
|
||||||
|
</equals>
|
||||||
|
</condition>
|
||||||
|
<property>/systems/pressurization/outflowpos-man</property>
|
||||||
|
</input>
|
||||||
|
<input>
|
||||||
|
<condition>
|
||||||
|
<equals>
|
||||||
|
<property>/systems/pressurization/auto</property>
|
||||||
|
<value>1</value>
|
||||||
|
</equals>
|
||||||
|
</condition>
|
||||||
|
<property>/systems/pressurization/outflowpos-norm-cmd</property>
|
||||||
|
</input>
|
||||||
|
<output>/systems/pressurization/outflowpos-norm</output>
|
||||||
|
</filter>
|
||||||
|
|
||||||
<filter>
|
<filter>
|
||||||
<name>Cabin VS</name>
|
<name>Cabin VS</name>
|
||||||
<type>noise-spike</type>
|
<type>noise-spike</type>
|
||||||
|
@ -424,6 +450,26 @@
|
||||||
<output>/systems/pressurization/targetvs-cmd</output>
|
<output>/systems/pressurization/targetvs-cmd</output>
|
||||||
</filter>
|
</filter>
|
||||||
|
|
||||||
|
<filter>
|
||||||
|
<name>VS-target-cmd-man</name>
|
||||||
|
<type>gain</type>
|
||||||
|
<gain>1</gain>
|
||||||
|
<update-interval-secs type="double">0.05</update-interval-secs>
|
||||||
|
<input>
|
||||||
|
<expression>
|
||||||
|
<table>
|
||||||
|
<property>/systems/pressurization/outflowpos-man</property>
|
||||||
|
<entry><ind>0</ind><dep>-1000</dep></entry>
|
||||||
|
<entry><ind>0.5</ind><dep>0</dep></entry>
|
||||||
|
<entry><ind>1</ind><dep>2500</dep></entry>
|
||||||
|
</table>
|
||||||
|
</expression>
|
||||||
|
</input>
|
||||||
|
<output>/systems/pressurization/manvs-cmd</output>
|
||||||
|
</filter>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<filter>
|
<filter>
|
||||||
<name>VS-target</name>
|
<name>VS-target</name>
|
||||||
<type>gain</type>
|
<type>gain</type>
|
||||||
|
|
Reference in a new issue